package com.ruoyi.system.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.CmAnonymousComeMapper;
import com.ruoyi.system.domain.CmAnonymousCome;
import com.ruoyi.system.service.ICmAnonymousComeService;
import com.ruoyi.common.core.text.Convert;

/**
 * 访客管理Service业务层处理
 * 
 * @author pop404NotFound
 * @date 2021-12-11
 */
@Service
public class CmAnonymousComeServiceImpl implements ICmAnonymousComeService 
{
    @Autowired
    private CmAnonymousComeMapper cmAnonymousComeMapper;

    /**
     * 查询访客管理
     * 
     * @param id 访客管理主键
     * @return 访客管理
     */
    @Override
    public CmAnonymousCome selectCmAnonymousComeById(Long id)
    {
        return cmAnonymousComeMapper.selectCmAnonymousComeById(id);
    }

    /**
     * 查询访客管理列表
     * 
     * @param cmAnonymousCome 访客管理
     * @return 访客管理
     */
    @Override
    public List<CmAnonymousCome> selectCmAnonymousComeList(CmAnonymousCome cmAnonymousCome)
    {
        return cmAnonymousComeMapper.selectCmAnonymousComeList(cmAnonymousCome);
    }

    /**
     * 新增访客管理
     * 
     * @param cmAnonymousCome 访客管理
     * @return 结果
     */
    @Override
    public int insertCmAnonymousCome(CmAnonymousCome cmAnonymousCome)
    {
        return cmAnonymousComeMapper.insertCmAnonymousCome(cmAnonymousCome);
    }

    /**
     * 修改访客管理
     * 
     * @param cmAnonymousCome 访客管理
     * @return 结果
     */
    @Override
    public int updateCmAnonymousCome(CmAnonymousCome cmAnonymousCome)
    {
        return cmAnonymousComeMapper.updateCmAnonymousCome(cmAnonymousCome);
    }

    /**
     * 批量删除访客管理
     * 
     * @param ids 需要删除的访客管理主键
     * @return 结果
     */
    @Override
    public int deleteCmAnonymousComeByIds(String ids)
    {
        return cmAnonymousComeMapper.deleteCmAnonymousComeByIds(Convert.toStrArray(ids));
    }

    /**
     * 删除访客管理信息
     * 
     * @param id 访客管理主键
     * @return 结果
     */
    @Override
    public int deleteCmAnonymousComeById(Long id)
    {
        return cmAnonymousComeMapper.deleteCmAnonymousComeById(id);
    }
}
